<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script>
        //字符串不可变
        var str ='andy';
        console.log(str);
        str = 'red';
        console.log(str);

        //因为字符串的不可变所以不要大量拼接字符串
        var str = '';
        for (var i = 1;i<=100;i++){
            str += i;
        }
        console.log(str);
    </script>
</head>
<body>

</body>
</html>